<template>
	<view class="content-box">
		<view class="information" v-for="(item ,index) in list" :key="index" @click="$routeTo('/pages/me/train/trainDetails?content='+item.content)">
			<view class="text">
				<view class="title">
					{{item.title}}
				</view>
				<view class="bottom">
					<view class="time">
						{{item.updateTime}}
					</view>
				</view>
			</view>
			<view class="image">
				<u--image :showLoading="true"
					:src="$imageUrl(item.image)||'http://cdn.uviewui.com/uview/empty/data.png'" width="240rpx"
					height="180rpx"></u--image>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				list:[]
			}
		},
		onLoad() {
			let data={
				page:1,
				size:100
			}
			this.$myRequest('/api/driver/mine/v1/page/informationArticle',data).then(res => {
				this.list=res.data.data
			})
		},
		methods: {
			
		}
	}
</script>

<style lang="scss">
	.content-box{
		padding: 20rpx;
		min-height: calc(100vh - 40rpx);
	}
	.information {
		background-color: #FFFFFF;
		padding: 12upx 0;
		padding-top: 20rpx;
		margin-bottom: 20rpx;
		display: flex;
		// margin: 20upx;
		border-bottom: 2rpx solid #DCDCDC;
	
		.text {
			flex: 1;
			display: flex;
			flex-direction: column;
	
			.title {
				flex: 1;
				font-size: 28upx;
				color: #333333;
				font-weight: 700;
				overflow: hidden;
				text-overflow: ellipsis;
				display: -webkit-box;
				-webkit-line-clamp: 2;
				-webkit-box-orient: vertical;
	
	
			}
	
			.bottom {
				display: flex;
				justify-content: space-between;
				align-items: center;
				font-size: 22rpx;
				color: #999999;
	
				.time {
					font-size: 20upx;
				}
			}
		}
	
		.image {
			width: 240upx;
			height: 180upx;
			margin-left: 14upx;
			border-radius: 12upx;
			overflow: hidden;
		}
	}
</style>
